package com.yixun.driver.util;

import java.io.File;
import java.io.IOException;

public class GetAbsolutePath {

    //根据项目相对路径获取绝对路径的字符串
    public static String getAbsPath(String raletivePath)
    {
        //String  raletivePath="src/test/java/com/yixun/driver/deviceData.txt";
        String AbsPath="";

        File directory = new File(raletivePath);
        try {
            AbsPath = directory.getCanonicalPath();
        } catch (IOException e) {
            e.printStackTrace();
        }
        return AbsPath;
    }
}
